//
//  SelectCoursesCell.m
//  Menu
//
//  Created by mc on 16/4/12.
//  Copyright © 2016年 xmj. All rights reserved.
//

#import "SelectCoursesCell.h"
#import "SelectCourses.h"
#import <UIImageView+WebCache.h>

@interface SelectCoursesCell()
@property (weak, nonatomic) IBOutlet UIImageView *selectCoursesImageView;
@property (weak, nonatomic) IBOutlet UILabel *titleLabel;
@property (weak, nonatomic) IBOutlet UILabel *priceLabel;
@end

@implementation SelectCoursesCell

- (void)setSelectCourse:(SelectCourses *)selectCourse{
    self.priceLabel.layer.cornerRadius = 5;
    self.priceLabel.clipsToBounds = YES;
    self.priceLabel.backgroundColor = [UIColor colorWithRed:198.0/255 green:179.0/255 blue:120.0/255 alpha:1];
    _selectCourse = selectCourse;
    self.titleLabel.text = selectCourse.title;
    [self.selectCoursesImageView sd_setImageWithURL:[NSURL URLWithString:selectCourse.albums]];
}

#define IPHONE6_SIZE(X)  ([UIScreen mainScreen].bounds.size.width/(750.0/2.0))*X

+ (CGFloat)height{
    return IPHONE6_SIZE(255);
    //iphone6 shipei  375kuan  ;320   height = (yuanlaideHegiht/375)* [scere].width
    
    
}
@end
